import ReactDOM from 'react-dom'

const list = [
  { id: 1, name: '武汉黑马前端64期', salary: 11000 },
  { id: 2, name: '武汉黑马前端66期', salary: 13000 },
  { id: 3, name: '武汉黑马前端68期', salary: 15000 },
]
const tempArr = list.map((item) => (
  <li key={item.id}>
    <h3>{item.name}</h3>
    <p>工资：{item.salary}</p>
  </li>
))

// 渲染谁、渲染到哪里
ReactDOM.render(<ul>{tempArr}</ul>, document.querySelector('#root'))
